package com.iscale.model.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import java.util.Date;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import java.io.Serializable;


/**
 * <p>
 * 文件信息
 * </p>
 *
 * @author Andychen
 * @since 2017-03-10
 */
@SuppressWarnings("serial")
@JsonIgnoreProperties(ignoreUnknown = true)
@TableName("base_file_info")
public class BaseFileInfo extends Model<BaseFileInfo> {

    private static final long serialVersionUID = 1L;

	@TableId(value = "id", type = IdType.ID_WORKER)//分布式全局唯一 IdType.ID_WORKER
	private Long id;
    /**
     * 文件类型
     */
	@TableField("fileType")
	private String fileType;

	/**
	 * 商户编号
	 */
	@TableField("merchantNo")
	private String merchantNo;
    /**
     * 文件名
     */
	@TableField("fileName")
	private String fileName;
    /**
     * 文件全路径
     */
	@TableField("fileUrl")
	private String fileUrl;
    /**
     * 文件相对地址
     */
	@TableField("filePath")
	private String filePath;
    /**
     * 缩略图路径
     */
	@TableField("fileThumbnailUrl")
	private String fileThumbnailUrl;
    /**
     * 文件大小
     */
	@TableField("fileSize")
	private Long fileSize;

	/**
	 * 文件格式
	 */
	@TableField("fileFormat")
	private String fileFormat;
    /**
     * 重命名文件名
     */
	@TableField("keyName")
	private String fileRename;
    /**
     * 创建者
     */
	@TableField("createUser")
	private String createUser;
    /**
     * 创建时间
     */
	@TableField("createTime")
	private Date createTime;
    /**
     * 更新者
     */
	@TableField("updateUser")
	private String updateUser;
    /**
     * 更新时间
     */
	@TableField("updateTime")
	private Date updateTime;
	private Long rank;
    /**
     * 文件状态　０－正常　　１－删除
     */
	private Integer status;


	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getFileType() {
		return fileType;
	}

	public void setFileType(String fileType) {
		this.fileType = fileType;
	}

	public String getMerchantNo() {
		return merchantNo;
	}

	public void setMerchantNo(String merchantNo) {
		this.merchantNo = merchantNo;
	}

	public String getFileName() {
		return fileName;
	}

	public void setFileName(String fileName) {
		this.fileName = fileName;
	}

	public String getFileUrl() {
		return fileUrl;
	}

	public void setFileUrl(String fileUrl) {
		this.fileUrl = fileUrl;
	}

	public String getFilePath() {
		return filePath;
	}

	public void setFilePath(String filePath) {
		this.filePath = filePath;
	}

	public String getFileThumbnailUrl() {
		return fileThumbnailUrl;
	}

	public void setFileThumbnailUrl(String fileThumbnailUrl) {
		this.fileThumbnailUrl = fileThumbnailUrl;
	}

	public Long getFileSize() {
		return fileSize;
	}

	public void setFileSize(Long fileSize) {
		this.fileSize = fileSize;
	}

	public String getFileFormat() {
		return fileFormat;
	}

	public void setFileFormat(String fileFormat) {
		this.fileFormat = fileFormat;
	}

	public String getFileRename() {
		return fileRename;
	}

	public void setFileRename(String fileRename) {
		this.fileRename = fileRename;
	}

	public String getCreateUser() {
		return createUser;
	}

	public void setCreateUser(String createUser) {
		this.createUser = createUser;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getUpdateUser() {
		return updateUser;
	}

	public void setUpdateUser(String updateUser) {
		this.updateUser = updateUser;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public Long getRank() {
		return rank;
	}

	public void setRank(Long rank) {
		this.rank = rank;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	public BaseFileInfo(){}

	public BaseFileInfo(String fileType, String merchantNo, String fileName, String fileUrl, String filePath, Long fileSize, String fileFormat, String createUser) {
		this.fileType = fileType;
		this.merchantNo = merchantNo;
		this.fileName = fileName;
		this.fileUrl = fileUrl;
		this.filePath = filePath;
		this.fileSize = fileSize;
		this.fileFormat = fileFormat;
		this.createUser = createUser;
		this.createTime = new Date();
		this.status = 0;
	}
}
